﻿<?php
require_once('../../config.php');
 require_once($CFG->libdir . '/adminlib.php');
 require_once($CFG->dirroot . '/local/myplugin/lib.php');
require_once($CFG->dirroot . "/local/myplugin/forms.php");

/* Ket noi den file javascript - module.js */
$PAGE->requires->js_init_call('M.local_myplugin');	
	
	/* CSS */
$cssdir =  $CFG->wwwroot.'/local/myplugin/mycss.css';
echo '<link rel="stylesheet" href="'.$cssdir.'" type="text/css" media="screen" />';
//echo '<link rel="stylesheet" href="style.css" type="text/css" media="screen" />';

/* Chuan bi trang web can hien thi */	
$url = new moodle_url($CFG->wwwroot.'local/myplugin/cdiosubjectblock.php');
$PAGE->set_url($url);
$PAGE->set_title('CDIO-based curriculum');
$PAGE->set_heading('Môn học - Khối kiến thức');
$PAGE->set_pagelayout('standard');

//Them thanh menu ngang ung voi trang trong duong link
navigation_node::override_active_url(new moodle_url($CFG->wwwroot.'/local/myplugin/monhoc_giaoduc_daicuong.php', array('param'=>'value')));

echo $OUTPUT->header();

/* Viet doan code cua ban o day */
//load mon hoc vao select
$giaoducdc_form=new form_subject_giao_duc_dai_cuong();

//bat su kien nhan nu cancel
if ($giaoducdc_form->is_cancelled()) {

echo 'Hủy thao tác';

}
//kiem tra neu dc submitted thì làm gì
if ($fromform = $giaoducdc_form->get_data()) 
{
	$select=$_POST['chosensubject'];
	$count= count($_POST['chosensubject']);
}

if ($fromform=$giaoducdc_form->no_submit_button_pressed())
{
	 

}
$giaoducdc_form->display();


/*------Ket thuc doan code cua ban-------*/


echo $OUTPUT->footer();

